﻿using Windows.Service.Share;

namespace Windows.WorkFlow.Service
{
    public interface IFlowService
    {
        /// <summary>
        /// 流程视图
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        Task<PageResponse<FlowResponse>> Query(PageRequest<FlowRequest> request);
        /// <summary>
        /// 获取id的流程详情
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<FlowResponse> Detail(int id);
        /// <summary>
        /// 流程保存
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        Task Save(FlowSaveRequest request);
        /// <summary>
        /// 流程删除
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        Task Remove(IdsRequest request);
        /// <summary>
        /// 获取当前用户可用的流程列表
        /// </summary>
        /// <returns></returns>
        Task<List<FlowResponse>> GetCurrentCanUseFlows();
        /// <summary>
        /// 根据Id获取要发布的信息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<FlowPublishResponse> GetFlowPublishInfo(long id);
    }
    
}
